package net.kucoe.grin.internal;

import java.util.Map;

import net.kucoe.grin.Parameter;

/**
 * Internal actor that communicates to any other actor for result and uses system input for
 * interactions.
 * 
 * @author Vitaliy Basyuk
 */
public class InputInitialActor {
    
    private Map<String, Object> arguments;
    
    /**
     * Returns the arguments Map<String, Object>.
     * 
     * @return the arguments Map<String, Object>.
     */
    public Map<String, Object> getArguments() {
        return arguments;
    }
    
    /**
     * Overrides arguments the arguments.
     * 
     * @param arguments the arguments to set.
     */
    public void setArguments(final Map<String, Object> arguments) {
        this.arguments = arguments;
    }
    
    @Parameter
    protected Object get(final String name) {
        return arguments == null ? null : arguments.get(name);
    }
    
}
